﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Navigation;
using System.Windows.Shapes;
using SilverBox.Services;
using SilverBox.Demo.Log;

namespace SilverBox.Demo
{
    public partial class Logging : Page
    {
        /// Look out http://msdn.microsoft.com/en-us/magazine/dd458794.aspx to know
        /// where the log is being saved.

        public Logging()
        {
            InitializeComponent();
        }

        // Executes when the user navigates to this page.
        protected override void OnNavigatedTo(NavigationEventArgs e)
        {
        }



        private void Button_Click(object sender, RoutedEventArgs e)
        {
            var entry = EntryTextBox.Text;
            var myEntry = new MyEntry { 
                Title = "Custom Event",
                Content = entry
            };
            LoggerService.Current.Log(myEntry);            
        }
    }
}